-
-
Notifications
You must be signed in to change notification settings - Fork 648
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix post install message for JanePHP components #1748
Conversation
Thanks for the PR 😍 How to test these changes in your application
Diff between recipe versionsIn order to help with the review stage, I'm in charge of computing the diff between the various versions of patched recipes. jane-php/json-schema5.0 vs 6.0diff --git a/jane-php/json-schema/5.0/bin/jane-generate b/jane-php/json-schema/6.0/bin/jane-json-schema-generate
similarity index 50%
rename from jane-php/json-schema/5.0/bin/jane-generate
rename to jane-php/json-schema/6.0/bin/jane-json-schema-generate
index 0b13fca6..7fa9edfc 100755
--- a/jane-php/json-schema/5.0/bin/jane-generate
+++ b/jane-php/json-schema/6.0/bin/jane-json-schema-generate
@@ -3,11 +3,13 @@
require __DIR__ . '/../vendor/autoload.php';
-use Jane\JsonSchema\Command\GenerateCommand;
+use Jane\JsonSchema\Console\Command\GenerateCommand;
use Symfony\Component\Console\Input\ArrayInput;
use Symfony\Component\Console\Output\NullOutput;
+use Jane\JsonSchema\Console\Loader\ConfigLoader;
+use Jane\JsonSchema\Console\Loader\SchemaLoader;
-$command = new GenerateCommand();
-$inputArray = new ArrayInput(['--config-file' => __DIR__ . '/../config/jane/config.php'], $command->getDefinition());
+$command = new GenerateCommand(new ConfigLoader(), new SchemaLoader());
+$inputArray = new ArrayInput(['--config-file' => __DIR__ . '/../config/jane/json_schema.php'], $command->getDefinition());
$command->execute($inputArray, new NullOutput());
diff --git a/jane-php/json-schema/5.0/config/jane/config.php b/jane-php/json-schema/6.0/config/jane/json_schema.php
similarity index 100%
rename from jane-php/json-schema/5.0/config/jane/config.php
rename to jane-php/json-schema/6.0/config/jane/json_schema.php
diff --git a/jane-php/json-schema/5.0/config/packages/jane.yaml b/jane-php/json-schema/6.0/config/packages/jane.yaml
index 59ff9b33..4bc2f383 100644
--- a/jane-php/json-schema/5.0/config/packages/jane.yaml
+++ b/jane-php/json-schema/6.0/config/packages/jane.yaml
@@ -1,25 +1,6 @@
services:
- jane.serializer.json_encode:
- class: Symfony\Component\Serializer\Encoder\JsonEncode
- arguments:
- - { json_encode_options: 64 } # \JSON_UNESCAPED_SLASHES
+ _defaults:
+ autowire: true
+ autoconfigure: true
- jane.serializer.json_decode:
- class: Symfony\Component\Serializer\Encoder\JsonDecode
- arguments:
- - { json_decode_associative: false }
-
- jane.serializer.json_encoder:
- class: Symfony\Component\Serializer\Encoder\JsonEncoder
- arguments:
- - '@jane.serializer.json_encode'
- - '@jane.serializer.json_decode'
-
-# jane.serializer.object:
-# class: MyApp\Library\Generated\Normalizer\JaneObjectNormalizer
-#
-# jane.serializer:
-# class: Symfony\Component\Serializer\Serializer
-# arguments:
-# - ['@serializer.denormalizer.array', '@jane.serializer.object']
-# - ['@jane.serializer.json_encoder']
+# MyApp\Library\Generated\Normalizer\JaneObjectNormalizer: null
diff --git a/jane-php/json-schema/5.0/manifest.json b/jane-php/json-schema/6.0/manifest.json
index e2920638..a55f0fce 100644
--- a/jane-php/json-schema/5.0/manifest.json
+++ b/jane-php/json-schema/6.0/manifest.json
@@ -2,5 +2,8 @@
"copy-from-recipe": {
"bin/": "%BIN_DIR%/",
"config/": "%CONFIG_DIR%/"
+ },
+ "conflict": {
+ "symfony/symfony": "<5.0"
}
}
diff --git a/jane-php/json-schema/5.0/post-install.txt b/jane-php/json-schema/6.0/post-install.txt
index 8b1d9fea..f9596417 100644
--- a/jane-php/json-schema/5.0/post-install.txt
+++ b/jane-php/json-schema/6.0/post-install.txt
@@ -1,8 +1,8 @@
* Finish package configuration:
- 1. Configure config/jane/config.php with your specification details
- 2. Run bin/jane-generate
+ 1. Configure config/jane/json_schema.php with your specification details
+ 2. Run bin/jane-json-schema-generate
3. Add generated/ directory to your composer autoload definition (eg. "MyApp\\Library\\Generated\\": "generated/")
- 4. Open config/packages/jane.yaml and replace MyApp\Library\Generated\Normalizer\JaneObjectNormalizer class with your generated normalizer.
+ 4. Open config/packages/jane.yaml and replace MyApp\Library\Generated namespace with your generated namespace.
5. Then remove line comments
Documentation: https://jane.readthedocs.io/en/latest/ 6.0 vs 7.0diff --git a/jane-php/json-schema/6.0/bin/jane-json-schema-generate b/jane-php/json-schema/7.0/bin/jane-json-schema-generate
index 7fa9edfc..55e71e67 100755
--- a/jane-php/json-schema/6.0/bin/jane-json-schema-generate
+++ b/jane-php/json-schema/7.0/bin/jane-json-schema-generate
@@ -3,11 +3,11 @@
require __DIR__ . '/../vendor/autoload.php';
-use Jane\JsonSchema\Console\Command\GenerateCommand;
+use Jane\Component\JsonSchema\Console\Command\GenerateCommand;
+use Jane\Component\JsonSchema\Console\Loader\ConfigLoader;
+use Jane\Component\JsonSchema\Console\Loader\SchemaLoader;
use Symfony\Component\Console\Input\ArrayInput;
use Symfony\Component\Console\Output\NullOutput;
-use Jane\JsonSchema\Console\Loader\ConfigLoader;
-use Jane\JsonSchema\Console\Loader\SchemaLoader;
$command = new GenerateCommand(new ConfigLoader(), new SchemaLoader());
$inputArray = new ArrayInput(['--config-file' => __DIR__ . '/../config/jane/json_schema.php'], $command->getDefinition()); jane-php/open-api-common6.0 vs 7.0diff --git a/jane-php/open-api-common/6.0/bin/jane-open-api-generate b/jane-php/open-api-common/7.0/bin/jane-open-api-generate
index ab6ef287..7f5f95a6 100755
--- a/jane-php/open-api-common/6.0/bin/jane-open-api-generate
+++ b/jane-php/open-api-common/7.0/bin/jane-open-api-generate
@@ -3,12 +3,12 @@
require __DIR__ . '/../vendor/autoload.php';
-use Jane\OpenApiCommon\Console\Command\GenerateCommand;
+use Jane\Component\OpenApiCommon\Console\Command\GenerateCommand;
+use Jane\Component\OpenApiCommon\Console\Loader\ConfigLoader;
+use Jane\Component\OpenApiCommon\Console\Loader\OpenApiMatcher;
+use Jane\Component\OpenApiCommon\Console\Loader\SchemaLoader;
use Symfony\Component\Console\Input\ArrayInput;
use Symfony\Component\Console\Output\NullOutput;
-use Jane\OpenApiCommon\Console\Loader\ConfigLoader;
-use Jane\OpenApiCommon\Console\Loader\OpenApiMatcher;
-use Jane\OpenApiCommon\Console\Loader\SchemaLoader;
$command = new GenerateCommand(new ConfigLoader(), new SchemaLoader(), new OpenApiMatcher());
$inputArray = new ArrayInput(['--config-file' => __DIR__ . '/../config/jane/open_api.php'], $command->getDefinition()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks
There was a
\
in front of a</>
which was breaking coloration. This PR is fixing this issue.